You are here: Symbol Reference > Dew Namespace > Dew.Math Namespace > Classes > TOpenCLMtxVec Class > TOpenCLMtxVec Methods > ImagPart Method > TOpenCLMtxVec.ImagPart Method ([In] TOpenCLMtxVec)
Dew Math for .NET
ContentsIndexHome
PreviousUpNext
TOpenCLMtxVec.ImagPart Method ([In] TOpenCLMtxVec)

Gets the imaginary part of a complex object.

Syntax
C#
Visual Basic
public TOpenCLMtxVec ImagPart([In] TOpenCLMtxVec Vec);

Gets the imaginary part of a complex object Vec and stores the real results in the calling object. Size and TOpenCLBase.ComplexComplexproperties of the calling object are set implicitly to match Vec object. Vec TOpenCLBase.ComplexComplexmust be true otherwise the exception will be raised.

using Dew.Math; using Dew.Math.Units; namespace Dew.Examples() { void Example() { TOpenCLVector a,b; clMtxVec.CreateIt(out a, out b); try { a.CopyCplxFromArray(new double[] {1,2,3,4}); // a= [1+2i, 3+4i] b.ImagPart(a); // b = [2, 4] } finally { clMtxVec.FreeIt(ref a,ref b); } } }
Copyright (c) 1999-2024 by Dew Research. All rights reserved.
What do you think about this topic? Send feedback!